<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=0"/>
<script src="https://cdn.bootcss.com/jquery/2.0.0/jquery.min.js"></script>  
<title>test</title>
<style>
body,p { margin:0; padding:0;}
.concent { margin:50px auto; width:100%; max-width:750px; min-width:320px; }
.box { white-space:nowrap; overflow-x:auto; }							
.box::-webkit-scrollbar { width:0; height:0; display: none; }     
.box div { list-style:none; display:inline-block; width:100px; line-height:30px; margin-right:10px; 
background:#ccc; text-align:center; }	
.box p { width:100%; height:50px; background:pink; }
.box div:last-child { margin:0; }
</style>
</head>
<body>
<div class="concent">
	<div class="box">	
	    <div>
            <p></p><b>1</b></div><div>
            <p></p><b>2</b></div><div>
            <p></p><b>3</b></div><div>
            <p></p><b>4</b></div><div>
            <p></p><b>5</b></div><div>
            <p></p><b>6</b></div><div>
            <p></p><b>7</b></div><div>
            <p></p><b>8</b></div>
	</div>
</div>
<script>
    var oBox = $('.box');
    var oBoxWidth = $('.box').width();
 
    oBox.find('div').on('click',function(){
	var thisWidth = $(this).width();
	var moveLeft = this.offsetLeft;
	if(oBoxWidth<moveLeft+thisWidth){
	    oBox.animate({scrollLeft:moveLeft});
	}else{
	    oBox.animate({scrollLeft:0});	
	}
    });
</script>
</body>
</html>